import { Http } from '@/common/api'
// 用户管理
export const listUrl = '/srm/rectify/page'

/**
 * 删除整改通知
 * @param rectifyId
 * @returns {Promise<unknown>}
 */
export const apiDeleteRectifyInform = async (rectifyId) => Http.delete(`/srm/rectify/delete?rectifyId=${rectifyId}`)
/**
 * 确认整改措施
 * @param rectifyId
 * @returns {Promise<unknown>}
 */
export const apiConfirmRectifyInform = async (rectifyId) => Http.put(`/srm/rectify/confirmReply?rectifyId=${rectifyId}`)

/**
 * 新增整改通知
 * @param params
 * @returns {Promise<unknown>}
 */
export const apiAddRectifyInform = async (params) => Http.post('/srm/rectify/add', params)
/**
 * 修改整改通知
 * @param params
 * @returns {Promise<unknown>}
 */
export const apiUpdateRectifyInform = async (params) => Http.post('/srm/rectify/update', params)
/**
 * 获取整改通知详情
 * @param rectifyId
 * @returns {Promise<unknown>}
 */
export const apiGetRectifyInformDetail = async (rectifyId) => Http.get(`/srm/rectify/detail?rectifyId=${rectifyId}`)
/**
 * 驳回整改措施
 * @param params
 * @returns {Promise<unknown>}
 */
export const apiRejectRectify = async (params) => Http.put('/srm/rectify/rejectReply', params)
/**
 * 确认整改结果
 * @param params
 * @returns {Promise<unknown>}
 */
export const apiReplyResult = async (params) => Http.put('/srm/rectify/replyResult', params)
/**
 * 批量发送整改通知
 * @param {string[]}ids
 * @returns {Promise<unknown>}
 */
export const apiMultipleSend = async (ids) => Http.put('/srm/rectify/batch/send', ids)

/**
 * 确认整改措施
 * @param rectifyId
 * @returns {Promise<unknown>}
 */
export const apiConfirmReply = async (rectifyId) => Http.put(`/srm/rectify/confirmReply?rectifyId=${rectifyId}`)
